import Login from "@/pages/Login";
import Register from "@/pages/Register";
import Dashboard from "@/pages/Dashboard";
import Projects from "@/pages/Projects";
import PublicBugs from "@/pages/PublicBugs";
import PersonalBugs from '@/pages/PersonalBugs'
import UploadSoftware from "@/pages/UploadSoftware";
import ProjectDetails from "@/pages/ProjectDetails";
import SystemSettings from "@/pages/SystemSettings";
import { createBrowserRouter } from 'react-router-dom';

// 路由实例配置
const router = createBrowserRouter([
    {
        path: '/login',
        element: <Login />
    },
    {
        path: '/register',
        element: <Register />
    },
    {
        path: '/',
        element: <Dashboard />
    },
    {
        path: '/projects',
        element: <Projects />
    },
    {
        path: '/publicvulnerability',
        element: <PublicBugs />
    },
    {
        path: '/personalvulnerability',
        element: <PersonalBugs />
    },
    {
        path: '/upload',
        element: <UploadSoftware />
    },
    {
        path: '/project/detail/:pkg_filename',
        element: <ProjectDetails/>
    },
    {
        path: '/systemsettings',
        element: <SystemSettings />
    },
]);

export default router;